<!-- 头部区域（水平导航） -->
{block name="menu_h"}
    {if condition="count($user.menu.menu_h.menu_h_s) > 0"}
    <li class="layui-nav-item layui-hide-xs">
        <a href="javascript:;" layadmin-event="more">查询中心</a>
        <dl class="layui-nav-child">
        {foreach $user.menu.menu_h.menu_h_s as $key => $value}
            {if condition="isset($value['sub'])"}
                {foreach $value['sub'] as $k => $v}
                    {if condition="$v.type eq 'select'"}
                        <dd class="nav-item"><a lay-href="{$v.url}" data-id="{$v.id}" data-title="{$v.alt}" data-type="tabAdd">{$v.alt}</a></dd>
                    {/if}
                {/foreach}
            {else/}
                {if condition="$value.type eq 'select'"}
                    <dd class="nav-item"><a lay-href="{$value.url}" data-id="{$value.id}" data-title="{$value.alt}" data-type="tabAdd">{$value.alt}</a></dd>
                {/if}
            {/if}
        {/foreach}
        </dl>
    </li>
    {/if}

    {if condition="count($user.menu.menu_h.menu_h_c) > 0"}
    <li class="layui-nav-item layui-hide-xs">
        <a href="javascript:;" layadmin-event="more">控制中心</a>
        <dl class="layui-nav-child">
            {foreach $user.menu.menu_h.menu_h_c as $key => $value}
                {if condition="isset($value['sub'])"}
                    {foreach $value['sub'] as $k => $v}
                        {if condition="$v.type eq 'contrl'"}
                            <dd class="nav-item"><a lay-href="{$v.url}" data-id="{$v.id}" data-title="{$v.alt}" data-type="tabAdd">{$v.alt}</a></dd>
                        {/if}
                    {/foreach}
                {else/}
                    {if condition="$value.type eq 'contrl'"}
                        <dd class="nav-item"><a lay-href="{$value.url}" data-id="{$value.id}" data-title="{$value.alt}" data-type="tabAdd">{$value.alt}</a></dd>
                    {/if}
                {/if}
            {/foreach}
        </dl>
    </li>
    {/if}
{/block}

<!-- 左侧导航区域（垂直导航） -->
{block name="menu_v"}
    {foreach $user.menu.menu_v as $key => $value}
        {if condition="isset($value['sub'])"}
            <li class="layui-nav-item nav-item">
                <i class="layui-icon layui-icon-{$value.icon}"></i>
                <a lay-href="{$value.url}" data-id="{$value.id}" data-title="{$value.alt}">
                    <cite>{$value.alt}</cite>
                </a>
                {foreach $value['sub'] as $k => $v}
                    <dl class="layui-nav-child">
                        <dd>
                            <a lay-href="{$v.url}" data-id="{$v.id}" data-title="{$v.alt}" data-type="tabAdd">
                                <cite>{$v.alt}</cite>
                            </a>
                        </dd>
                    </dl>
                {/foreach}
            </li>
        {else/}
            <li class="layui-nav-item nav-item">
                <a lay-href="{$value.url}" data-id="{$value.id}" data-title="{$value.alt}" data-type="tabAdd">
                    <i class="layui-icon layui-icon-{$value.icon}"></i>
                    <cite>{$value.alt}</cite>
                </a>
            </li>
        {/if}
    {/foreach}
{/block}